// 商品分类
import http from '../request'
// 获取所有商品分类信息
export function getAllGoodsApi(params){
  return http({
    method:'GET',
    url:'/api/shop/classify',
    params
  })
}
// 获取每个分类的商品信息
export function getGoodsApi(params){
  return http({
    method:'GET',
    url:'/api/shop/classify/classifyGoods',
    params
  })
}
// 获取单个商品分类信息 
export function getShopApi(id,params){
  return http({
    method:'GET',
    url:`/api/shop/classify/${id}`,
    params
  })
}
// 获取热门商品(根据已销售数量)
export function hotShopApi(params){
  return http({
    method:'GET',
    url:`/api/shop/goods/hotGoods`,
    params
  })
}
// 搜索商品
export function getSearchShopApi(params){
  return http({
    method:'GET',
    url:`/api/shop/goodsSearch`,
    params
  })
}